'use strict';
// Copyright 2014 Blueant Inc. All Rights Reserved.

/**
 * @fileoverview 资源商城
 * @author sundbcn@gmail.com (sun debing)
 */

var shopBuy = require('./shop/buy');
var shopList = require('./shop/list');
var vipShopBuy = require('./shop/vipShopBuy');
var vipShopList = require('./shop/vipShopList');
var discountShop = require('./shop/discountShop.js');
var discountList = require('./shop/discountList.js');

module.exports = function (app) {
    return new Handler(app);
};

var Handler = function (app) {
    this.app = app;
};

/**
 * 资源商城购买
 */
Handler.prototype.buy = function (msg, session, next) {
    shopBuy(msg, session, next);
};

/**
 * 资源商城列表
 */
Handler.prototype.list = function (msg, session, next) {
    shopList(msg, session, next);
};

/**
 * vip特权礼包列表
 */
Handler.prototype.vipShopList = function (msg, session, next) {
    vipShopList(msg, session, next);
};

/**
 * vip特权礼包列表
 */
Handler.prototype.vipShopBuy = function (msg, session, next) {
    vipShopBuy(msg, session, next);
};

/**
 *  折扣商店
 */
Handler.prototype.discountShop = function (msg, session, next) {
    discountShop(msg, session, next);
};

/**
 *  折扣商店列表
 */
Handler.prototype.discountList = function (msg, session, next) {
    discountList(msg, session, next);
};
